<div class="modal" ng-controller="KisBpmAssignmentPopupCtrl">
    <div class="modal-dialog" ng-click="stop($event)">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true" ng-click="close()">&times;</button>
                <h2 translate>PROPERTY.ASSIGNMENT.TITLE</h2>
            </div>
            <div class="modal-body">
            
            	<div class="row row-no-gutter">
            		<div class="form-group">
            			<label for="assigneeField">{{'审批人配置' | translate}}</label>
            			<input type="text" id="assigneeField" class="form-control" ng-model="assignment.assignee" placeholder="{{'PROPERTY.ASSIGNMENT.ASSIGNEE_PLACEHOLDER' | translate}}" />
            		</div>
            	</div>
            	
                <div class="row row-no-gutter">
                    <div class="form-group">
                        <label for="userField">{{'岗位选择' | translate}}</label>
                        <div  class="container">
                                <div class="row">
                                    <tree-view 
                                    tree-data="treeData" 
                                    text-field="name" 
                                    value-field='icon' 
                                    item-clicked="itemClicked($item)" 
                                    item-checked-changed="itemCheckedChanged($item)" 
                                    can-checked="true" 
                                    >	
                                    </tree-view>
                                </div>
                                <script type="text/ng-template" id="/treeView.html">
                                    <ul class="tree-view">
                                        <li ng-repeat="item in treeData" ng-include="itemTemplateUrl || '/treeItem.html'" ></li>
                                    </ul>
                                </script>
                                <script type="text/ng-template" id="/treeItem.html">
                                    <i ng-click="itemExpended(item, $event);" class="{{getItemIcon(item)}}"></i>
                                    <input type="checkbox" 
                                    ng-model="item.$$isChecked" 
                                    class="check-box" 
                                    ng-disabled = 'item.disabled'
                                    ng-if="canChecked" 
                                    ng-change="warpCallback('itemCheckedChanged', item, $event)">
                                    <span class='text-field' ng-click="warpCallback('itemClicked', item, $event);">{{item[textField]}}</span>
                                    <ul ng-if="!isLeaf(item)"    ng-show="item.$$isExpend">
                                        <li ng-repeat="item in item.childList" ng-include="itemTemplateUrl || '/treeItem.html'"></li>
                                    </ul>
                                </script>
                            </div>
                        </div>
                    </div>

                        <!-- <div ng-repeat="candidateUser in assignment.candidateUsers">
            	            <input id="userField" class="form-control" type="text" ng-model="candidateUser.value" />
            	            <i class="glyphicon glyphicon-minus clickable-property" ng-click="removeCandidateUserValue($index)"></i>
            	            <i ng-if="$index == (assignment.candidateUsers.length - 1)" class="glyphicon glyphicon-plus clickable-property" ng-click="addCandidateUserValue($index)"></i> 
                        </div>
                       </div> -->
                       
                    <div class="form-group">
                        <label for="groupField">{{'选人策略' | translate}}</label>
                        <p style="min-height: 20px; border:1px solid #ccc" ng-click="show=!show">{{selectArr.join(',')}}</p>
                        <div style="height: 100px; overflow: auto">
                            <div ng-repeat="(key, value) in selectDatas" ng-show="show" >
                                <input type="checkbox" ng-model='value.isShow' ng-change="fn(value)"><label for="">{{value.strategyName}}</label>
                            </div>
                        </div>
                       <!-- <div ng-repeat="candidateGroup in assignment.candidateGroups"> </div>  -->
                        <!-- <div ng-repeat="candidateGroup in assignment.candidateGroups">                        
            	          	<input id="groupField" class="form-control" type="text" ng-model="candidateGroup.value" /> 
            	          	<i class="glyphicon glyphicon-minus clickable-property" ng-click="removeCandidateGroupValue($index)"></i>
            	          	<i ng-if="$index == (assignment.candidateGroups.length - 1)" class="glyphicon glyphicon-plus clickable-property" ng-click="addCandidateGroupValue($index)"></i>
                        </div> -->
                    </div>
                </div>
                
                
                
          
            <div class="modal-footer">
                <button ng-click="close()" class="btn btn-primary" translate>ACTION.CANCEL</button>
                <button ng-click="save()" class="btn btn-primary" translate>ACTION.SAVE</button>
            </div>
        </div>
    </div>
</div>

